Skip to content

Fix coloring of methods and add throughput lines in network vs runtime plots - #201

Merged
CodyCBakerPhD merged 8 commits into
mainfrom
fix_method_colors
Oct 11, 2026
Merged

CodyCBakerPhD merged 8 commits into
mainfrom
fix_method_colors

Conversation

@oruebel

@oruebel oruebel commented Oct 5, 2026

Copy link
Copy Markdown
Contributor
  • The colors for different methods were chosen within each function, which led to inconsistent colors in particular when select methods were for some reason missing in a plot. This PR adds a fixed color palette to ensure consistent assignment of colors to methods across all plots.
  • Add throughput (MB/s) lines to the plots showing the network traffic vs runtime

Copilot AI balanced review requested due to automatic review settings October 5, 2026 04:25

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟡 Changes recommended

Fallback colors remain subset-dependent, and throughput guides misrepresent non-byte metrics.

Review effort: Balanced
Findings: 2 Medium severity

Open (2)
What changed in this PR

Standardizes method colors across benchmark plots and adds throughput references to network-traffic-versus-runtime visualizations.

Changes:

  • Adds a shared method palette across plot types.
  • Adds dashed throughput guides, captions, and adjusted titles.
File Description
src/​nwb_benchmarks/​database/​_visualization.py Centralizes method colors and adds throughput overlays.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread src/nwb_benchmarks/database/_visualization.py Outdated
Comment thread src/nwb_benchmarks/database/_visualization.py Outdated
@oruebel
oruebel requested review from CodyCBakerPhD and rly October 5, 2026 04:39
@CodyCBakerPhD

Copy link
Copy Markdown
Collaborator

One minor recommendation, either/or:

  • Swap #9467BD for a color that also differs in brightness, for example a dark brown like #8C510A
  • Tell zarr s3 and zarr s3 force no consolidated apart by marker or line style instead, since they're variants of the same method

@CodyCBakerPhD

Copy link
Copy Markdown
Collaborator

@oruebel ping on these suggestions; happy to make them directly if you prefer

@oruebel

oruebel commented Oct 11, 2026

Copy link
Copy Markdown
Contributor Author

happy to make them directly if you prefer

sure, feel free to add them directly

CodyCBakerPhD and others added 3 commits October 11, 2026 15:51
… version (follow-up to #201) (#215)

Applies both suggestions from
[#201](#201 (comment)),
which @oruebel agreed to in [this
comment](#201 (comment)).
Targets the `fix_method_colors` branch so it folds into #201.

- Swap `#9467BD` (purple) for `#8C510A` (dark brown) as the color of
`zarr s3 force no consolidated`, so it differs from the yellow of `zarr
s3` in brightness as well as hue. The `pynwb` variant picks up the same
color through the existing derived mapping.
- Tell the unconsolidated Zarr variant apart from `zarr s3` by line
style and marker as well: it is drawn dash-dot with square markers (new
`DEFAULT_METHOD_LINESTYLES` / `DEFAULT_METHOD_MARKERS` next to
`DEFAULT_METHOD_COLORS`, with the same PyNWB derivation). Applied in
every plot that connects points per method: the slicing and file-open
network-vs-runtime plots (legend handles included), the slice-size and
performance-over-versions point plots via seaborn's `markers` /
`linestyles`, and the download-vs-stream extrapolation lines. Dash-dot
rather than dashed so the variant does not collide with the dashed gray
throughput guide lines added in #201.
- Bump the package version to `0.2.2` (main is now at `0.2.1` after
#210), since #201 changes code under `src/nwb_benchmarks/` and its
`version-check` CI run is currently failing for the missing bump (patch
bump per `AGENTS.md`: a fix that leaves what the benchmarks measure
alone).

Smoke-tested each changed plot path on synthetic data; `black` and
`isort` pass.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

https://claude.ai/code/session_01E6ccBQPZ1RBwpZvme23B2t

---------

Co-authored-by: Claude <noreply@anthropic.com>
@CodyCBakerPhD
CodyCBakerPhD merged commit 3c36106 into main Oct 11, 2026
4 of 5 checks passed
@CodyCBakerPhD
CodyCBakerPhD deleted the fix_method_colors branch October 11, 2026 19:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants